<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0,user-scalable=no">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <title>兆千图</title>
    <link rel="stylesheet" href="../../css/api.css">
    <link rel="stylesheet" href="../../css/news.css">
    <link rel="stylesheet" href="../../css/win.css">
    <link rel="stylesheet" href="../../css/video.css">
    <style>
        html,
        body {
            background: transparent;
        }

        .back {
            position: relative;
            left: 0;
        }

        #fx-header {
            background: transparent;
        }
        #fx-footer {
            position: fixed;
            bottom: 0;
            width: 100%;
        }

        #fx-footer .btn-wrap {
            padding: 20px 30px;
            text-align: center;
        }

        #fx-footer .btn-wrap button {
            color: #fff;
            margin-top: 15px;
            font-size: 14px;
        }
        .camera {
            text-align: center;
            /* position: absolute;
            right: 20px; */
            width: 30vw;
        }

        .camera img {
            width: 35px;
        }

        .camera .text {
            font-size: 14px;
            color: #fff;
            margin-top: 20px;
        }
    </style>
</head>

<body>
    <div class="wrap " id="view" v-cloak>
        <header id="fx-header">
            <div class="head new-padding-10">
                <div class="back" tapmode onclick="exitRoom()"> </div>
            </div>
        </header>
        <footer id="fx-footer">
            <div :class="{'flex-bt':true}">
                <div class="camera" onclick="switchCamera()">
                    <img src="../../image/chat/photo_footage_icon.png" alt="">
                    <p class="text">{{_i18n('切换摄像头')}}</p>
                </div>

                <div class="camera"  onclick="openMeiyan()">
                    <img src="../../image/photograph_btn_tags.png" alt="">
                    <p class="text">{{_i18n('美颜')}}</p>
                </div>
            </div>
        </footer>

    </div>
</body>
<script src="../../script/api.js"></script>
<script src="../../script/jquery.js"></script>
<script src="../../script/ffkj.js"></script>
<script src="../../script/vue.js"></script>
<script src="../../script/mhsdk.js"></script>
<script>
    var view = new Vue({
        el: '#view',
        data: {
            imgurl: imgurl,
            ffList: [],
            ffInfo: {},
            ios: 1, // 1上架 0非上架
            sex: '',

            toolSelect: -1,

            mp: 0,
            mb: 0,
            hr: 0,
            lj: 0,

        },
        methods: {
            // 美颜等级选择
            setLevel(type) {
                var _this = this;
                api.execScript({
                    name: 'frame4/meiyan_win',
                    frameName: 'frame4/meiyan_frm',
                    script: 'setLevel("' + type + '",' + _this[type] + ')'
                })
            },
            // 美颜 当前类型的效果选择
            setEffect(index) {
                var _this = this;
                _this.toolSelect = index;
                api.execScript({
                    name: 'frame4/meiyan_win',
                    frameName: 'frame4/meiyan_frm',
                    script: 'setEffect(' + index + ')'
                })
            },
            _url(param, url) {
                _url(param, url);
            },
            // 图片
            returnImg(url) {
                return returnImg(url);
            },
        }
    })
    apiready = function() {
        $api.fixStatusBar($api.byId('fx-header'));
    }

    // 离开房间
    function exitRoom() {
        api.execScript({
            name: 'frame4/mhui_set',
            frameName: 'frame4/mhui_set',
            script: 'exitRoom()'
        })
    }

    function openMeiyan() {
        api.execScript({
            name: 'frame4/mhui_set',
            frameName: 'frame4/mhui_set',
            script: 'openMeiyan()'
        })
    }

    // 切换摄像头
    function switchCamera() {
        api.execScript({
            name: 'frame4/mhui_set',
            frameName: 'frame4/mhui_set',
            script: 'switchCamera()'
        })
    }
</script>

</html>